package com.example.main.Conditional.ConditionalOnBean2;

import java.lang.annotation.*;

import org.springframework.context.annotation.Conditional;

/**
 * 当value 的 实例化bean存在的时候，就实例化当前bean。
 * 
 * @author <a href="mailto:zhoufei@smartdot.com">周飞</a>
 * @since 2021/9/12 14:50
 */
@Target({ ElementType.TYPE, ElementType.METHOD })
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Conditional(OnBean2Condition.class)
public @interface ConditionalOnBean2 {
    
    Class<?> value() default Object.class;
    
}
